
package fileby.gui.breadcrumbs;

import com.google.inject.Inject;
import fileby.core.IDisplayableFileSource;
import fileby.ctrl.breadcrumbs.IBreadCrumbListenerProvider;
import fileby.ctrl.transferhandlers.ITransferHandlerProvider;
import fileby.util.properties.IPropertyBundleProvider;
import javax.swing.JPanel;

/**
 *
 * @author Ludwig Kjellstrom
 */
public class BreadCrumbFactory implements IBreadCrumbProvider{

    private IPropertyBundleProvider propertyBundleProvider;
    private ITransferHandlerProvider transferHandlerProvider;
    private IBreadCrumbListenerProvider listenerProvider;

    @Inject
    public BreadCrumbFactory(IPropertyBundleProvider propertyBundleProvider,
            ITransferHandlerProvider transferHandlerProvider,
            IBreadCrumbListenerProvider listenerProvider) {

        this.propertyBundleProvider = propertyBundleProvider;
        this.transferHandlerProvider = transferHandlerProvider;
        this.listenerProvider = listenerProvider;
    }

    public JPanel create(IDisplayableFileSource displayableFileSource){
        return new BreadCrumb(displayableFileSource,propertyBundleProvider,
                transferHandlerProvider, listenerProvider);
    }

}
